#ifndef QTTEST_LOOPER_H
#define QTTEST_LOOPER_H

#include "./Message.h"
#include "./MessageQueue.h"
#include <deque>
#include <mutex>

class Looper {
public:
    void enQueue(Message *msg);

    Message *deQueue();

    static void loop();

    static Looper *prepare();

    static Looper *getThreadLocalLooper();

private:
    MessageQueue mMsgQ;
};

#endif //QTTEST_LOOPER_H

